package com.yilin.tms.core.entity.data.invoice;

import com.baomidou.mybatisplus.annotation.EnumValue;
import com.baomidou.mybatisplus.annotation.TableName;
import com.yilin.tms.core.commons.base.BaseDataEntity;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;

/**
 * 发票抬头
 *
 * @author zhangjinyuan
 * @date 2022/9/6
 */
@Entity
@Table(name = "data_invoice_header")
@TableName("data_invoice_header")
public class InvoiceHeader extends BaseDataEntity {

    /**
     * 抬头类型
     */
    public enum HeaderType {
        individual(0,"个人"),
        company(1,"公司");

        @EnumValue
        public Integer index;
        public String name;

        HeaderType(Integer index, String name) {
            this.index = index;
            this.name = name;
        }
    }

    //申请人商户ID
    @Column(name = "organize_id")
    private String organizeId;
    //申请人ID
    @Column(name = "apply_user_id")
    private String applyUserId;
    //申请人名称
    @Column(name = "apply_user_name")
    private String applyUserName;

    //是否增值税发票
    @Column(name = "is_vat")
    private Boolean isVat;
    //是否是默认使用的抬头
    @Column(name = "is_default")
    private Boolean isDefault;
    //抬头类型
    @Column(name = "header_type")
    private HeaderType headerType;
    //发票抬头名称(公司名称/个人名字)
    @Column(name = "invoice_title")
    private String invoiceTitle;
    //公司税号
    @Column(name = "vat_company_name")
    private String vatCompanyName;
    //公司地址
    @Column(name = "vat_company_address")
    private String vatCompanyAddress;
    //联系电话
    @Column(name = "vat_tel_phone")
    private String vatTelPhone;
    //开户银行
    @Column(name = "vat_bank_name")
    private String vatBankName;
    //银行帐号
    @Column(name = "vat_bank_account")
    private String vatBankAccount;

    public String getOrganizeId() {
        return organizeId;
    }

    public void setOrganizeId(String organizeId) {
        this.organizeId = organizeId;
    }

    public String getApplyUserId() {
        return applyUserId;
    }

    public void setApplyUserId(String applyUserId) {
        this.applyUserId = applyUserId;
    }

    public String getApplyUserName() {
        return applyUserName;
    }

    public void setApplyUserName(String applyUserName) {
        this.applyUserName = applyUserName;
    }

    public Boolean getVat() {
        return isVat;
    }

    public void setVat(Boolean vat) {
        isVat = vat;
    }

    public Boolean getDefault() {
        return isDefault;
    }

    public void setDefault(Boolean aDefault) {
        isDefault = aDefault;
    }

    public HeaderType getHeaderType() {
        return headerType;
    }

    public void setHeaderType(HeaderType headerType) {
        this.headerType = headerType;
    }

    public String getInvoiceTitle() {
        return invoiceTitle;
    }

    public void setInvoiceTitle(String invoiceTitle) {
        this.invoiceTitle = invoiceTitle;
    }

    public String getVatCompanyName() {
        return vatCompanyName;
    }

    public void setVatCompanyName(String vatCompanyName) {
        this.vatCompanyName = vatCompanyName;
    }

    public String getVatCompanyAddress() {
        return vatCompanyAddress;
    }

    public void setVatCompanyAddress(String vatCompanyAddress) {
        this.vatCompanyAddress = vatCompanyAddress;
    }

    public String getVatTelPhone() {
        return vatTelPhone;
    }

    public void setVatTelPhone(String vatTelPhone) {
        this.vatTelPhone = vatTelPhone;
    }

    public String getVatBankName() {
        return vatBankName;
    }

    public void setVatBankName(String vatBankName) {
        this.vatBankName = vatBankName;
    }

    public String getVatBankAccount() {
        return vatBankAccount;
    }

    public void setVatBankAccount(String vatBankAccount) {
        this.vatBankAccount = vatBankAccount;
    }
}
